Defining navigation areas and breadcrumb areas

Caution! The four default navigation areas provided with WCM (Primary, Secondary, Auxiliary, and Footer) are used by iMIS. If you delete these navigation areas or modify their properties, you might adversely affect the normal functioning of iMIS. If you need a different navigation behavior for an iMIS site, always create new navigation areas for the site, then modify the site's master page to use the new navigation areas.

To specify which navigation areas to use in a site

In Site Designer, select Manage websites, and then Edit the site. In the Navigation Areas section, select the checkboxes for each navigation area that you want to be available for use by navigation items that you define in the sitemap for this site, then click Save.

If you clear any checkboxes that were previously selected in this section, all navigation items that are currently defined to be displayed in that navigation area will still appear in that navigation area in rendered site pages. This happens because the master page for the site still contains a framework for the navigation area, and currently published navigation items still contain the properties that make them be displayed in the navigation area that you no longer want to be available for use in this site. The navigation area will not completely disappear from your rendered site until you edit and save every existing navigation item in the site's sitemap.

To delete navigation areas from the entire system

Caution! You must not delete or change the properties of the four default navigation areas provided with WCM: Primary, Secondary, Auxiliary, and Footer. These navigation areas are also used by iMIS. If you want to remove one of these default navigation areas from a site, it is safer to do so by removing the corresponding control from the site's master page.

You should avoid deleting a navigation area unless you are very sure of the ramifications, because doing so will remove the navigation area from the entire system, which affects all iMIS sites in the system.

In Site Designer, select Manage websites, and then Edit any site in the list (because they all share the same list of available navigation areas). In the Navigation Areas section, click the Create or Edit Navigation Panes icon. In the window that appears, click delete next to the navigation item that you want to delete from the system.

When you delete a navigation area, all navigation items that are currently defined to be displayed in that navigation area will still appear in that navigation area in rendered site pages, because the master page for the site still contains a framework for the navigation area, and published navigation items still contain the properties that make them be displayed in the deleted navigation area. The navigation area will not completely disappear from all of your rendered sites until you edit and save every navigation item in the system that currently uses that navigation area.

To edit the properties of existing navigation areas

Caution! You must not delete or change the properties of the four default navigation areas provided with WCM: Primary, Secondary, Auxiliary, and Footer. These navigation areas are also used by iMIS. If you want to change the behavior of one of these default navigation areas, it is safer to do so by creating an entirely new navigation area with the desired properties and then modifying the controls on the site's master page to use these new replacement navigation areas.

The properties of a navigation area are applied equally across all sites that use the navigation area. You must consider this effect when changing the properties of a navigation area.

In Site Designer, select Manage websites, then Edit any site in the list (because they all share the same list of available navigation areas). In the Navigation Areas section, click the Create or Edit Navigation Panes icon. In the window that appears, click select next to the navigation area that you want to edit.

To add new navigation areas to the system and to master pages

Because the properties of a navigation area are applied equally across all sites that use the navigation area, the way that you make a certain navigation area behave differently from site to site is by creating new navigation areas that are each used in the same general area of each site's master page, but that have different properties from each other. This process requires you to first add the new navigation item to the system, and then to modify the desired section of each site's master page to use the appropriate navigation area.

For example, you might want the Primary navigation area in two different sites to behave differently from each other. You would create a new navigation area named something like Primary2, making its properties slightly different from the Primary navigation area. No change would be needed to the master pages for sites that use the Primary navigation area. But the sites that you specify to instead use Primary2 would need to have their master pages edited to use the Primary2 navigation area in the section where they were previously coded to use the Primary navigation area.

In Site Designer, select Manage websites, and then Edit any site in the list (because they all share the same list of available navigation areas). In the Navigation Areas section, click the Create or Edit Navigation Panes icon. In the window that appears, click add at the top of the list of navigation area. Define the properties of the new navigation area and click Save. Then click select next to the newly-created navigation area and write down the displayed Navigation Pane Code and Name.

In the master page for sites that will use this new navigation area, you can either modify existing navigation-handling controls to use the new navigation area, or you can add entirely new navigation-handling controls to the already existing set in the master page.

■    To modify an existing navigation-handling control, replace the value of the control's ID attribute with the Name that you recorded previously, and replace the value of the control's NavigationPaneCode attribute with the Navigation Pane Code that you recorded previously. The default navigation-handling controls in the master page are:

□    For the Primary navigation area - <asi:PageNav>

□    For the Secondary navigation area - <asi:PageSubNav>

□    For the Auxiliary navigation area - <asiweb:NavigationList> (ID="Auxiliary")

□    For the Footer navigation area - <asiweb:NavigationList> (ID="Foot")

■    To add an entirely new navigation-handling control, copy either the Auxiliary or Footer control and paste it into an appropriate section of the master page. Then replace the value of the control's ID attribute with the Name that you recorded previously, and replace the value of the control's NavigationPaneCode attribute with the Navigation Pane Code that you recorded previously.

To add a breadcrumb area to master pages

To add a breadcrumb-handling control to a hand-built master page, copy the following code from any ASI-developed master page (which all contain a breadcrumb area) into an appropriate DIV of the master page.

Note: The administrative views do not support breadcrumb-handling controls.

Note: The default ASP.NET breadcrumb control is not recommended for the WCM environment. The following compatible breadcrumb control should be used in its place, which enables the navigation item's Title and it's corresponding Breadcrumb Name displayed in the breadcrumb area to be different from each other.

<asp:Panel ID="TaskPanel" runat="server">

   <asp:Label ID="TaskDescription" runat="server" Visible="false"></asp:Label>

   <asiweb:SiteMapPath ID="BreadCrumb" runat="server" SiteMapProvider="AsiSiteMapProvider">

       <NodeTemplate>

          <asp:HyperLink ID="NodeLink" runat="server" NavigateUrl='<%# Eval("Url") %>'

             Text='<%# Eval("NavigationHierarchy.Navigation.BreadCrumbName") %>'

             CssClass="BreadCrumbLink">

          </asp:HyperLink>

       </NodeTemplate>

       <CurrentNodeTemplate>

          <asp:Label ID="CurrentNodeLabel"

             runat="server"

             Text='<%# Eval("NavigationHierarchy.Navigation.BreadCrumbName") %>'>

          </asp:Label>

       </CurrentNodeTemplate>

   </asiweb:SiteMapPath>

</asp:Panel>

Troubleshooting

■    You must be a member of at least one content authority group (CAG).

■    You must have administrative access to the entire file system on your iMIS application server and on all the external web servers that you use for hosting iMIS sites.

■    If you are planning to add an entirely new navigation area to your system (instead of reusing one of your currently defined navigation areas), ensure that you have not already exceeded the system limit of 30 uniquely defined navigation areas. Four default navigation areas (Primary, Secondary, Auxiliary, and Footer) are predefined in iMIS.

■    You must be familiar with ASP.NET development techniques and the design and construction of ASP.NET master pages.

Note: Membership in the SysAdmin security role effectively grants the full set of Document System permissions and the full set of CAG permissions (you are effectively a member of a MasterAdmin CAG too). However, to participate in web content authoring workflow, even members of the SysAdmin role must be an explicitly-listed member of at least one CAG.

Tips

The following information can be helpful when defining navigation areas and breadcrumb areas.

How the automated contents of navigation areas are determined

A combination of user-defined settings in Site Designer and the choice of three possible ASI-developed controls used in a site's master page determine what is displayed in each navigation area defined in the master page.

When you define navigation items in Site Designer, there are three properties you specify that relate to the hierarchy of the site's sitemap:

■    Static Display Levels

■    Dynamic Display Levels

■    Starting Level

To understand the interplay of these three properties, see the Navigation Areas section of Fields: websites. In short, these properties are only defaults that are subsequently overridden to varying degrees by the type of control you use in the master page to render the navigation areas.

In the master pages:

■    Primary navigation (if present) is rendered either by the asi:PageNav control (for older templates) or the asi:PageNavR control (for newer templates), which renders a larger set of horizontal, single-level, tab-style links above the main content area.

■    Secondary navigation (if present) is rendered by the asi:PageSubNav control, which renders a vertical set of expandable, multi-level, links at the left or right side of the main content area.

■    Auxiliary and Footer navigation (if present) are both rendered by the asiweb:NavigationList control, which renders a compact set of horizontal links, for placement near the top and bottom of the entire browser window.

In your own hand-built master pages, you can use any of these three controls to render any of the navigation areas used in the site. Which control you should use depends on the results you want to achieve, because each control overrides the default display level properties defined in each navigation area in different ways:

■    asi:PageNav and asi:PageNavR ignore the Starting Level and the Static Display Levels defined in the associated navigation area. It is hard-coded to start the first level of the sitemap hierarchy below the sitemap root (~), and then to display the number of additional sitemap levels defined in the Dynamic Display Levels of the associated navigation area.

For example, the default Primary navigation area is defined with a value of 0 for its Dynamic Display Levels. As a result, the Primary navigation area displays only the first level of the sitemap hierarchy below the sitemap root.

■    asi:PageSubNav ignores the Starting Level and the Dynamic Display Levels defined in the associated navigation area. This control is hard-coded to start at the second level of the sitemap hierarchy below the sitemap root (~), and then to display the number of additional sitemap levels defined in the Static Display Levels of the associated navigation item.

For example, the default Secondary navigation area is defined with a value of 4 for its Static Display Levels. As a result, the Secondary navigation area displays the second, third, fourth, and fifth levels of the sitemap hierarchy below the sitemap root. The default rendering behavior is to collapse all but the first of these four levels unless a descendant navigation item in the specified range is flagged to be expanded by default (with the This navigation item is expanded by default checkbox in the Options section).

You can change the starting level of the sitemap hierarchy displayed by this control by changing the value of the StartingNodeOffset attribute. The offset that you specify in this attribute must be the sitemap hierarchy level minus 1. So, StartingNodeOffset="1" makes the control start at the second level of the sitemap hierarchy, but in the 1504 template, StartingNodeOffset="0" makes the control start at the first level.

■    asiweb:NavigationList ignores the Starting Level, Static Display Levels, and Dynamic Display Levels. It is hard-coded to display only those navigation items that are flagged to be always shown in a navigation area that is rendered by this control (with the Show in the following navigation areas checkboxes in the Options section).

For example, the default Auxiliary and Footer navigation areas are rendered by this control. Only those navigation items in which Auxiliary and/or Footer checkboxes are selected beneath Show in the following navigation areas actually appear in the rendered output of this control.

The special primary footer

Master pages might insert a special "primary footer" that is not actually controlled by the Footer navigation area defined in WCM. This can cause some unexpected results when you designate navigation items for use in the Footer navigation area, because the navigation items that you designate appear only in the bottom row of footer links.

What appears to be a single set of footer links spanning two rows actually comprises two separate sets that are rendered by two different controls:

■    The top row of footer links is created by an asiweb:NavigationList control that is hard-coded with attributes to duplicate the content of only the first level of links shown in the Primary navigation area.

■    The bottom row of footer links is created by an asiweb:NavigationList control that is associated with the Footer navigation area defined in the system.

You can duplicate this "primary footer" technique in your own hand-built master pages by pasting the following two elements directly above the one that renders the Footer navigation area:

<asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" />

<asiweb:NavigationList ID="PrimaryFoot" runat="server" NavigationPaneCode="1"

    UseGenericMenu="true" StartFromRootNode="true" SelectDefaultNode="false"

    SiteMapDataSourceID="SiteMapDataSource1" />